#pragma once 
#include "ros/ros.h"
#include "nav_msgs/Path.h"
#include "agxcar_ctrl/lightcontrol.h"
#include "Eigen/Dense"

class trigger_response_action {
public:
    enum response_type {
        HOLD_ON = 0,
        PATROL = 1,
        FOLLOW = 2,
        ALARM  = 3,
        ATTACK = 4
    };

    // trigger_response_action(ros::NodeHandle & node);
    trigger_response_action(ros::NodeHandle & node, ros::NodeHandle & private_node);
    
    void trigger_response(const Eigen::Vector3d & UavPos, const Eigen::Vector3d & UgvPos, const  Eigen::Vector3d & TargetPos, int response_id);
    
    void publish_patrol_path();

    void alarm_light();

    void close_light();

    void attack_light();

    void target_pos_pub(const Eigen::Vector3d & TargetPos);

private:
    double waypoints_[4][3];
    int waypoint_num_ = 0;

    bool new_listservice;

    ros::NodeHandle & node_;
    ros::NodeHandle & private_node_;

    ros::Publisher ugv_path_pub_;
    ros::Publisher target_pos_pub_;
    ros::ServiceClient ugv_light_client_;
};